package amdocs.jet.pm.xml;

import java.text.SimpleDateFormat;

public class Currency implements Comparable<Currency>
{
	private String name;
	private String unit;
	private String currencyCode;
	private String country;
	private String rate;
	private String change;

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getUnit() {
		return unit;
	}

	public void setUnit(String unit) {
		this.unit = unit;
	}

	public String getCurrencyCode() {
		return currencyCode;
	}

	public void setCurrencyCode(String currencyCode) {
		this.currencyCode = currencyCode;
	}

	public String getCountry() {
		return country;
	}

	public void setCountry(String country) {
		this.country = country;
	}

	public String getRate() {
		return rate;
	}

	public void setRate(String rate) {
		this.rate = rate;
	}

	public String getChange() {
		return change;
	}

	public void setChange(String change) {
		this.change = change;
	}

	public int compareTo(Currency another) {
		return 1;
		//if (another == null) return 1;
		// sort descending, most recent first
		//return another.date.compareTo(date);
	}

	public Currency copy() 
	{
		Currency newCurrency = new Currency();
		newCurrency.change = change;
		newCurrency.country = country;
		newCurrency.currencyCode = currencyCode;
		newCurrency.name = name;
		newCurrency.rate = rate;
		newCurrency.unit = unit;
		return newCurrency;
	}
}
